//
//  OrderDetailsModel.m
//  StandardizedProduct
//
//  Created by 洛水寒 on 16/7/28.
//  Copyright © 2016年 ym. All rights reserved.
//

#import "OrderDetailsModel.h"

@implementation OrderDetailsModel
+ (OrderDetailsModel *)parseUserWithDictionary:(NSDictionary *)dict
{
    OrderDetailsModel *model = [[OrderDetailsModel alloc]init];
    /**商品名*/
    model.ProductName = [NSString stringWithFormat:@"%@", dict[@"ProductName"]];
    /**商品图*/
    model.goodsImg = [NSString stringWithFormat:@"%@%@", BaseURLStringString, dict[@"PicPath"]];
    /**类型*/
    if ([[NSString stringWithFormat:@"%@", dict[@"Color"]] isEqualToString:@"(null)"]) {
        model.goodsType = [NSString stringWithFormat:@"%@", dict[@"Size"]];
    }else if ([[NSString stringWithFormat:@"%@", dict[@"Size"]] isEqualToString:@"(null)"]){
        model.goodsType = [NSString stringWithFormat:@"%@", dict[@"Color"]];
    }else model.goodsType = [NSString stringWithFormat:@"%@,%@", dict[@"Color"], dict[@"Size"]];
    
    /**单价*/
    model.Price = [NSString stringWithFormat:@"%@", dict[@"Price"]];
    /**ProductCode*/
    model.ProductCode = [NSString stringWithFormat:@"%@", dict[@"ProductCode"]];
    /**ProductId*/
    model.ProductId = [NSString stringWithFormat:@"%@", dict[@"ProductId"]];
    /**邮费*/
    model.goodsfreight = @"0.00";
    /**数量*/
    model.Count = [NSString stringWithFormat:@"%@", dict[@"Count"]];
    /**Id*/
    model.goodsId = [NSString stringWithFormat:@"%@", dict[@"goodsId"]];
    /**订单Id*/
    model.OrderId = [NSString stringWithFormat:@"%@", dict[@"OrderId"]];
    /**订单号*/
    model.OrderNO = [NSString stringWithFormat:@"%@", dict[@"OrderNO"]];
    /**备注*/
    model.Remark = [NSString stringWithFormat:@"%@", dict[@"Remark"]];
    /**SKUId*/
    model.SkuId = [NSString stringWithFormat:@"%@", dict[@"SkuId"]];
    /**SKU*/
    model.SkuNO = [NSString stringWithFormat:@"%@", dict[@"SkuNO"]];
    /**总价*/
    model.TotalPrice = [NSString stringWithFormat:@"%@", dict[@"TotalPrice"]];
    /**交易号*/
    model.AddTime = [NSString stringWithFormat:@"%@", dict[@"AddTime"]];
    /**总运费*/
    model.goodsTotalFreight = @"0.00";
    /**运费险*/
    model.goodFreightSinsurance = @"0.00";
    
    return model;
}


@end
